package acm;

import java.util.Scanner;

public class 动态数组使用 {
    static int result=0;
    public static void main(String[] args){
        Scanner in = new Scanner(System.in);
        int number=in.nextInt();
        int[] a = new int[number];
        int m=0,pjz;
        for (int i=0;i<number;i++){
            a[i]=in.nextInt();
            m=add(a[i]);
        }
        pjz=m/number;
        System.out.print(m);
        System.out.print("  "+pjz);
    }
    public static int add(int b){
        result=result+b;
        return result;
    }
}
